<template>
  <a-layout-header class="headerBtn">
    <a-button type="danger" @click="logout">退出</a-button>
  </a-layout-header>
</template>

<script>
export default {
  methods: {
    logout() {
      window.sessionStorage.removeItem("token");
      this.$router.push({ name: "login" });
    },
  },
};
</script>

<style lang="scss" scoped>
.headerBtn {
  display: flex;
  justify-content: flex-end;
  align-items: center;
}
</style>